<%@ page language="java" import="java.util.*" pageEncoding="UTF-8" %>
<%@taglib prefix="s" uri="/struts-tags" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort() + path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
    <base href="<%=basePath%>">

    <title><s:property value="cate.name" /></title>

    <meta http-equiv="pragma" content="no-cache">
    <meta http-equiv="cache-control" content="no-cache">
    <meta http-equiv="expires" content="0">
    <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
    <meta http-equiv="description" content="This is my page">
	<script type="text/javascript" src="gko100/back/js/jquery-1.4.2.min.js"></script>  
    <script type="text/javascript" src="gko100/back/js/jquery.form.js"></script>        
    <script type="text/javascript">  
		function uploadImage() {  
		    $(document)  
		            .ready(  
		                    function() {  
		                        var options = {  
		                            url : "uploadFile.action",  
		                            type : "POST",  
		                            dataType : "script",  
		                            success : function(msg) {  
		                                if (msg.indexOf("#") > 0) {  
		                                    var data = msg.split("#");  
		                                    $("#tipDiv").html(data[0]);  
		                                    $("#showImage").html("<img src='showImage.action?imageUrl="+data[1]+"'/>");  
		                                } else {  
		                                    $("#tipDiv").html(msg);  
		                                }  
		                            }  
		                        };  
		                        $("#form2").ajaxSubmit(options);  
		                        return false;  
		                    });  
		}  
	</script>  
    <style>
			
			body {
				margin-left: 0px;
				margin-top: 0px;
				margin-right: 0px;
				margin-bottom: 0px;
			}
			.STYLE1 {font-size: 12px}
			.STYLE3 {font-size: 12px; font-weight: bold; }
			.STYLE4 {
				color: #03515d;
				font-size: 12px;
			}
			form {
				margin: 0;
			}
			textarea {
				display: block;
			}
			#main{
				margin-left:5px;
			}
		</style>
		
		
</head>

<body>

	<div id="main">
	    	<table width="100%" border="0" cellspacing="0" cellpadding="0">
				<tr>
			    	<td height="30" background="gko100/back/admin/images/tab_05.gif">
			    		<table width="100%" border="0" cellspacing="0" cellpadding="0">
			      			<tr>
			        			<td width="12" height="30">
			        				<img src="gko100/back/admin/images/tab_03.gif" width="12" height="30" />
			        			</td>
			        			<td>
			        				<table width="100%" border="0" cellspacing="0" cellpadding="0">
			          					<tr>
			            					<td width="46%" valign="middle">
			            						<table width="100%" border="0" cellspacing="0" cellpadding="0">
			              							<tr>
			                							<td width="5%">
			                								<div align="center">
			                									<img src="gko100/back/admin/images/tb.gif" width="16" height="16" />
			                								</div>
			                							</td>
			                							<td width="95%" class="STYLE1">
			                								<span class="STYLE3">当前位置</span>：[<s:property value="cate.name" />][更新信息]
			                							</td>
			              							</tr>
			            						</table>
			            					</td>
			          					</tr>
			        				</table>
			        			</td>
			        			<td width="16"><img src="gko100/back/admin/images/tab_07.gif" width="16" height="30" /></td>
			      			</tr>
			    		</table>
			    	</td>
			  	</tr>
			</table>
			<s:if test="nav!=null">
				<table style="width: 90%; border:1px #888 solid; align:center;">
					<tr style="background:#999">
						<th width="10%">模块</th>
						<th width="10%">模块名称</th>
						<th width="30%">模块链接</th>
						<th width="10%">备注</th>		
					</tr>
					
				</table>
			</s:if>
					
			<s:if test="nav.navPid==0">
				<form id="form2" method="post" enctype="multipart/form-data">  
		            <table width="400" border="1" cellspacing="1" cellpadding="10">  
		                <tr>  
		                    <td height="25">  
		                       	 浏览图片：  
		                    </td>  
		                    <td>  
		                        <input id="fileupload" name="fileupload" type="file" />  
		                        <div id="tipDiv"></div>  
		                    </td>  
		                </tr>  
		                <tr>  
		                    <td colspan="2" align="center">  
		                        <input type="button" class="right-button02"  
		                            onclick="uploadImage()" value="上传" />  
		                    </td>  
		                </tr>  
		            </table>  
		        </form>  
		        <br>  
		                     图片预览  
		        <div id="showImage"></div>  

			</s:if>
				
			
			<table style="width: 90%; border:1px #888 solid; align:center;">
				<form action="nav_modify" method="post" name="example" target="mainFrame">
					
					<tr>
						<td style="width: 10%; border:1px #888 solid; text-align: center;">子模块</td>
						<td style="width: 10%; border:1px #888 solid; text-align: center;"><input type="text" name="nav.navName" value="<s:property value='nav.navName' />" size="13px" /></td>
						<td style="width: 30%; border:1px #888 solid; text-align: center;"><input type="text" name="nav.NavUrl" value="<s:property value='nav.navUrl' />" size="50px" /></td>
						<td style="width: 10%; border:1px #888 solid; text-align: center;"><input type="text" name="nav.navNote" value="<s:property value='nav.navNote' />" size="13px" /></td>
					</tr>
					<tr>
						<td style="width: 5%; border:1px #888 solid; text-align: center;"><input type="submit" value="更新子模块" /></td>
						<td style="width: 5%; border:1px #888 solid; text-align: center;"><input type="reset" value="重新填写" /></td>
					</tr>

				</form>
			
			</table>
			

		
			
	    <s:debug></s:debug>
	
	</div>
</body>

</html>
